Preparing superpositions of computational basis states on a quantum computer

ABSTRACT

Methods, systems and apparatus for preparing arbitrary superposition quantum states of a quantum register on a quantum computer, the quantum state comprising a superposition of L computational basis states. In one aspect, a register of log L qubits is prepared in a weighted sum of register basis states, where each register basis state indexes a corresponding quantum state computational basis state, and the amplitude of each register basis state in the weighted sum of register basis states is equal to the amplitude of the corresponding computational basis state in the superposition of L computational basis states. A unitary transformation that maps the register basis states to the corresponding L computational basis states is then implemented, including, for each index 1 to L, controlling, by the register of log L qubits, transformation of the quantum system register state for the index to the corresponding computational basis state for the index.

BACKGROUND

This specification relates to quantum computing.

SUMMARY

This specification describes technologies for preparing an arbitrary superposition of computational basis states on a quantum computer.

In general, one innovative aspect of the subject matter described in this specification can be implemented in a method for preparing a quantum state of a quantum system register on a quantum computer, wherein the quantum state comprises a superposition of L computational basis states, the method comprising: preparing a register of log L qubits in an initial state, the initial state comprising a weighted sum of register basis states, wherein: each register basis state indexes a corresponding quantum state computational basis state, and the amplitude of each register basis state in the weighted sum of register basis states is equal to the amplitude of the corresponding computational basis state in the superposition of L computational basis states; and preparing the quantum state by implementing a unitary transformation that maps the register basis states to the corresponding L computational basis states, comprising, for each index 1 to L, controlling, by the register of log L qubits, transformation of the quantum system register state for the index to the corresponding computational basis state for the index.

Other implementations of this aspect include corresponding computer systems, apparatus, and computer programs recorded on one or more computer storage devices, each configured to perform the actions of the methods. A system of one or more classical and/or quantum computers can be configured to perform particular operations or actions by virtue of having software, firmware, hardware, or a combination thereof installed on the system that in operation causes or cause the system to perform the actions. One or more computer programs can be configured to perform particular operations or actions by virtue of including instructions that, when executed by data processing apparatus, cause the apparatus to perform the actions.

The foregoing and other implementations can each optionally include one or more of the following features, alone or in combination. In some implementations implementing a unitary transformation that maps the register basis states to the corresponding L computational basis states comprises implementing a unary iteration quantum circuit.

In some implementations controlling transformation of the quantum system register state for the index to the corresponding computational basis state for the index comprises controlling applications of unitary operators on the quantum system register state by a state of a unary register, wherein the state of the unary register is determined by the register of log L qubits.

In some implementations controlling applications of unitary operators on the quantum system register state by a state of a unary register comprises, for each index 1 to L: reading the computational basis state corresponding to the index to the quantum system register, comprising applying a unitary operator for the index to the system register controlled by the unary register; erasing the state of the register of log L qubits using a unitary operator controlled by the unary register; and uncomputing the unary register.

In some implementations the method further comprises providing the register of log L qubits for use in further computations.

In some implementations controlling applications of unitary operators on a system register encoding the quantum state by a unary register comprising the register of log L qubits comprises controlling applications of products of Pauli-X quantum logic gates.

In some implementations implementing a unitary transformation that maps the register basis states to the corresponding L computational basis states comprises applying select unitary methods.

In some implementations preparing the register of log L qubits in the initial state comprises applying quantum circuit synthesis techniques.

In some implementations the superposition of L computational basis states is determined using an adaptive sampling configuration interaction method.

In some implementations the method further comprises providing the quantum state for use in a quantum phase estimation algorithm.

In some implementations the method further comprises performing a quantum simulation using the prepared quantum state as an initial state of the quantum simulation.

In some implementations the quantum computer comprises a circuit model quantum computer.

Another innovative aspect of the subject matter described in this specification can be implemented in a method for preparing a target quantum state of a quantum system register on a quantum computer, wherein the target quantum state comprises a superposition of L computational basis states, the method comprising, sequentially for each index 1=1 to l=L: preparing the quantum system register and a unary register in a quantum state, wherein: the state of the quantum system register is entangled with the unary register, at an initial time step the state of the quantum system register equals the target quantum state up to the first (l−1) computational basis states if the state of the unary register is |0

, and the state of the quantum system register equals the l-th computational basis state if the unary register is in state |1

; selecting a qubit from the quantum system register whose value is different in the l-th computational basis state and the l+l-th computational basis state: applying a rotation to the selected qubit, wherein the rotation is controlled by the state of a unary register; erasing the unary register value for the l-th computational basis state; and implementing a NOT logic gate on the remaining qubits in the quantum system register whose values are different in the l-th computational basis state and the l+l-th computational basis state, wherein implementation of the NOT logic gate is controlled by the state of the unary register.

Other implementations of this aspect include corresponding computer systems, apparatus, and computer programs recorded on one or more computer storage devices, each configured to perform the actions of the methods. A system of one or more classical and/or quantum computers can be configured to perform particular operations or actions by virtue of having software, firmware, hardware, or a combination thereof installed on the system that in operation causes or cause the system to perform the actions. One or more computer programs can be configured to perform particular operations or actions by virtue of including instructions that, when executed by data processing apparatus, cause the apparatus to perform the actions.

The foregoing and other implementations can each optionally include one or more of the following features, alone or in combination. In some implementations preparing the quantum system register and a unary register in a quantum state comprises preparing the quantum system register and unary register in a quantum state |ψ_(l)

=β_(l)|D_(l)

|1

+Σ_(l′=1) ^(l-1)α_(l), |D_(l′)

|0

, wherein 1 represents the index, |D_(l)

represents the l-th computational basis state, α represents a computational basis state amplitude, and |β_(l)|=√{square root over (1−Σ_(l′=1) ^(l-1)|α_(l′)|²)}.

In some implementations the method further comprises ordering the computational basis states such that the Hamming distances between neighboring computational basis states are reduced.

In some implementations applying a rotation to the selected qubit comprises applying a Pauli X gate to the selected qubit.

In some implementations selecting a qubit from the quantum system register whose value is different the l-th computational basis state and the l+1-th computational basis state comprises selecting a qubit from the quantum system whose occupation numbers d_(l,k) and d_(l+1,k) are different.

In some implementations the amplitude of the l-th basis state is derived from normalization.

In some implementations |β_(l)| is derived from normalization.

In some implementations the superposition of L computational basis states is determined using an adaptive sampling configuration interaction method.

In some implementations the method further comprises providing the target quantum state for use in a quantum phase estimation algorithm.

In some implementations the method further comprises initializing a quantum simulation using the prepared target quantum state; and performing a the quantum simulation.

The subject matter described in this specification can be implemented in particular ways so as to realize one or more of the following advantages.

A system preparing quantum states using the techniques described in this specification can efficiently prepare superposition states of arbitrary size, since the cost of the quantum state procedure is, up to log factors, of O(L) where L represents the number of computational basis states. Since quantum state preparation is an essential component of many quantum computations and simulations, the presently filed subject matter thus increases the efficiency of such quantum computations and simulations. For example, phase estimation algorithms may be performed more efficiently and quantum simulations, e.g., of chemicals or materials, may be performed more efficiently.

In addition, systems implementing the techniques described in this specification may prepare larger superposition states at a same cost compared to other systems implementing conventional techniques. Since larger superposition states typically have a stronger support on target quantum states, this can increase the accuracy of quantum algorithms and computations that require the preparation of quantum states.

Near-term quantum computers can typically implement a limited number of reliable (e.g., high fidelity) quantum gates and therefore have limited computational power. Reducing the number of quantum gates used in the preparation of quantum computer quantum states can therefore free-up more of this limited computational power for performing quantum algorithms of interest. A system preparing quantum states using the techniques described in this specification can prepare superposition states using fewer T gates compared to other systems implementing conventional techniques. Since T gates are notoriously costly, a system preparing quantum states using the techniques described in this specification requires less computational resources compared to other systems implementing conventional techniques. In embodiments that utilise unary iteration techniques/circuits, the T-complexity (i.e. number of T-gates required) to produce superposition states can be further reduced.

In addition, a system preparing quantum states using the techniques described in this specification can prepare quantum states using a circuit that can be compiled more easily compared to systems using other techniques.

The details of one or more implementations of the subject matter of this specification are set forth in the accompanying drawings and the description below. Other features, aspects, and advantages of the subject matter will become apparent from the description, the drawings, and the claims.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a plot showing the overlap of the ground state of Nitrogen and Chromium dimers as a function of the number of computational basis states used to prepare an initial superposition state.

FIG. 2 depicts an example system.

FIG. 3 is a flow diagram of an example process for preparing a superposition of basis states using a compressed register of qubits.

FIG. 4 shows an example unary iteration quantum circuit.

FIG. 5 is a flowchart of an example process for loading data using unary iteration techniques

FIG. 6 is a flow diagram of an example process for preparing a superposition of basis states using two-dimensional rotations in the space of computational basis states.

FIG. 7 is a flow diagram of an example Adaptive Sampling Configuration Interaction algorithm.

DETAILED DESCRIPTION

Techniques for preparing and studying ground states of quantum systems, e.g., molecular systems, on a quantum computer include applying a quantum phase estimation algorithm to project an initial guess state |ψ

onto the ground state. The quantum phase estimation algorithm enables the phase accumulated on a quantum register under the action of a unitary operator U to be measured. Some varieties of phase estimation, such as iterative phase estimations and phase estimations based on the quantum Fourier transform, perform this measurement protectively, enabling sampling in the eigenbasis of the unitary operator U. In the context of quantum simulation, this unitary operator usually corresponds to time evolution under the system Hamiltonian H for time t. Therefore, performing projective phase estimation on this operator will collapse the initial guess state |ψ

to an eigenstate of the Hamiltonian with a probability that depends on the initial overlap between the initial guess state |ψ

and the eigenstate of interest. If H|n

=E_(n)|n

then performing phase estimation will project the system register to eigenstate |n

, and readout the associated eigenvalue E_(n) with probability p_(n)=

ψ|n

n|ψ

. Therefore, the number of times that phase estimation must be repeated to prepare the eigenstate |n

with high probability scales as 1/p_(n). For state preparation to be efficient, this probability is to decrease at most polynomially in the system size.

Accordingly, it is important to prepare initial states |ψ

for phase estimation with which the ground state has strong support, e.g., has an overlap that exceeds a predetermined threshold measured by the inner product. Preparing a single computational basis state as the initial state is straightforward but often a single computational basis state does not have strong support on the target eigenstate, and a superposition over a number of computational basis states provides a more suitable initial state. This is illustrated in FIG. 1, which shows the overlap of the ground state of Nitrogen and Chromium dimers as a function of the number of Slater determinants (computational basis states) used to prepare the initial superposition state. As shown in FIG. 1, there is a noticeable difference between starting in a wavefunction spanned by just one computational basis state and a wavefunction spanned by hundreds.

The present disclosure describes techniques for preparing an arbitrary superposition of computational basis states (also referred to herein as Slater determinants, as in the context of quantum chemistry) on a quantum computer. An example arbitrary superposition of L computational basis states is given by Equation (1) below.

$\begin{matrix} {\left. \psi_{in} \right\rangle = {\sum\limits_{l = 1}^{L}{\alpha_{l}\left. D_{l} \right\rangle}}} & (1) \end{matrix}$

In Equation (1), |D_(l)

represents an l-th computational basis state with amplitude α_(l). In a first method, the quantum state given by Equation (1) is prepared in a compressed register of qubits and its state is mapped to a superposition of basis states. In a second method, the quantum state given by Equation (1) is prepared using two-dimensional rotations in the space of computational basis states. Both methods use unary iteration techniques, as described below in more detail.

Example Hardware

FIG. 2 depicts an exemplary system 200 for preparing quantum states. The system 200 is an example of a system implemented as quantum or classical computer programs on one or more quantum computing devices or classical computers in one or more locations, in which the systems, components, and techniques described below can be implemented.

The system 200 includes a quantum computing device 202 in data communication with one or more classical processors 204. For convenience, the quantum computing device 202 and classical processors 204 are illustrated as separate entities, however in some implementations the one or more classical processors may be included in quantum computing device 202.

The quantum computing device 202 includes components for performing quantum computation. For example, the quantum computing device 202 includes quantum circuitry 206, control devices 208, and T factories 210. The quantum circuitry 206 includes components for performing quantum computations as sequences of quantum gates that implement transformations on qubits in one or more registers of qubits. For example, the quantum circuitry may include one or more quantum systems of multi-level quantum subsystems, e.g., registers of qubits 214. An example quantum circuit that may be implemented by the quantum computing device 202 is described below with reference to FIG. 4.

The type of multi-level quantum subsystems that the system 1200 utilizes may vary. For example, in some implementations the multi-level quantum subsystems may be superconducting qubits, e.g., Gmon or Xmon qubits. In some cases it may be convenient to include one or more resonators attached to one or more superconducting qubits. In other cases ion traps, photonic devices or superconducting cavities (with which states may be prepared without requiring qubits) may be used. Further examples of realizations of multi-level quantum subsystems include fluxmon qubits, silicon quantum dots or phosphorus impurity qubits.

Quantum circuits comprising different quantum logic operations, e.g., single qubit gates, two qubit gates, and three qubit gates such as logical AND operations, may be constructed using the quantum circuitry 206. Constructed quantum circuits can be operated/implemented using the control devices 208. The type of control devices 208 included in the quantum system depend on the type of qubits included in the quantum computing device. For example, in some cases the control devices 208 may include devices that control the frequencies of qubits included in the quantum circuitry 206, an excitation pulse generator and control lines that couple the qubits to the excitation pulse generator. The control devices may then cause the frequency of each qubit to be adjusted towards or away from a quantum gate frequency of an excitation pulse on a corresponding control driveline. The control devices 208 may further include measurement devices, e.g., readout resonators. Measurement results obtained via measurement devices may be provided to the classical processors 204 for processing and analyzing. The control devices may further include devices that can stabilize the phase of Rabi oscillation. For example, by weakly coupling a qubit to a microwave cavity, the system can monitor the qubit state non-destructively. An output signal can be amplified by a nearly noiseless parametric amplifier and measured by a homodyne process. The measurement signal may then be mixed with a reference signal using an analog multiplier, which serves as the input of the signal generator used to control the qubit state.

The system 200 may be configured to prepare a quantum system included in the quantum computing device 202 in a particular superposition of an arbitrary number of computational basis states using the techniques described herein. Once the quantum system has been prepared in the particular state, it may be used by the system 200 to perform quantum computations or simulations.

Programming the Hardware: Preparing Superposition States Using a Compressed Register of Qubits

FIG. 3 is a flow diagram of an example process 300 for preparing a quantum state of a quantum system register on a quantum computer, wherein the quantum state comprises a superposition of L computational basis states. In some implementations the superposition of L computational basis states may have been determined using an adaptive sampling configuration interaction method (as described in detail below). For brevity, the superposition of L basis states is referred to as a target quantum state |ψ_(in)

the below description, where the target quantum state is given by Equation (1) above.

For convenience, the process 300 will be described as being performed by a system of one or more classical and quantum computing devices located in one or more locations. For example, a quantum computation system, e.g., the system 200 of FIG. 2, appropriately programmed in accordance with this specification, can perform the process 300.

The system prepares a register of log L qubits in an initial state that includes a weighted sum of register basis states (step 302). Since the register of qubits includes log L qubits, the register may be referred to as a “compressed” register of qubits. Each register basis state indexes a corresponding quantum state computational basis state. For example, in cases where L=8, the compressed register may include Log 8=3 qubits whose basis state |000

represents the computational basis state |D₀

, |001

represents the computational basis state |D₁

, |010

represents the computational basis state |D₂

, |011

represents the computational basis state |D₃

, etc.

The amplitude of each register basis state in the weighted sum of register basis states is equal to the amplitude of the corresponding computational basis state in the superposition of L computational basis states. That is, the system may prepare the compressed register of qubits in a state |ϕ

, where |ϕ

can be given by Equation (2) below.

$\begin{matrix} {\left. \phi \right\rangle = {\sum\limits_{l = 1}^{L}{\alpha_{l}\left. l \right\rangle}}} & (2) \end{matrix}$

In Equation (2), the amplitudes α_(l) are the same as in Equation (1) above and |l

represents a basis state of the compressed register that indexes the computational basis state |D_(l)

of Equation (1).

To prepare the compressed register in the initial state that corresponds to the target quantum state, the system may apply techniques for initializing quantum registers such as those described in “Synthesis of quantum-logic circuits,” V. V. Shende et al, IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems 25, 1000 (2006). In some cases preparing the compressed register in the initial state may require O(L) quantum gates.

The system prepares the quantum state by implementing a unitary transformation that maps the basis states of the compressed register of log L qubits to the corresponding computational basis states (step 304). That is, the system implements a unitary transformation that maps |l

|D_(l)

for all l=1, 2, . . . , L where the computational state |D_(l)

is specified by the quantum system register qubit occupation numbers d_(l,1), d_(l,2), . . . d_(l,N) with N representing quantum system size.

In some implementations, the system may implement the unitary transformation by application of a unary iteration quantum circuit. An example unary iteration quantum circuit is described below with reference to FIG. 4. Applying the unitary iteration quantum circuit includes streaming over the quantum system register and storing the results in a unary register. The state of the unary register is determined by the register of log L qubits—the state of the unary register is |1

if the state of the quantum system register equals a selected basis state and is otherwise |0

. Performing indexed operations, e.g., data loading, using a unary iteration quantum circuit is described below with reference to FIG. 5. The compressed register of qubits can be mapped directly onto an index register of a unary iteration quantum circuit, making the method particularly suited to implementations using unary iteration quantum circuits.

To implement the unitary transformation, the system controls, sequentially for each index 1 to L and by the register of log L qubits, a transformation of the quantum system register state for the index to the corresponding computational basis state for the index. That is, for an l-th index, the system applies a unitary U_(l)=Π_(k=1) ^(N)X_(k) ^(d) ^(l,k) to the quantum system register controlled by the unary register, where X represents a Pauli X operator. This unitary only affects the state |l

of the compressed register, and the corresponding computational basis state is read to the quantum system register. Equation (3) gives an example mapping produced by this operation.

|l

|0

|l

|D _(l)

  (3)

This step requires O(NL) Clifford gates to implement and O(L) T gates.

The system may then erase the state of the compressed register using a unitary, e.g., a product of Pauli-X operators, controlled by the unary register. Equation (4) gives an example mapping produced by this operation.

|l

|D _(l)

|0

|D _(l)

  (4)

This step requires an additional O(log L) Clifford gates and zero T gates to implement in each step l=1 to L of unary iteration.

The system may then uncompute the unary register using the same data streaming method on the system register for the state |D_(l)

.

The total cost to prepare the quantum state is therefore O(NL+L log L) Clifford gates and O(L) T gates.

In other implementations the system may prepare the quantum state by implementing the unitary transformation using a select unitary method. Select unitary methods are described in “Toward the first quantum simulation with quantum speedup,” Childs et al, PNAS, Sep. 18, 2018 115 (38) 9456-9461.

In some implementations the system may provide the prepared quantum state for use in a quantum phase estimation algorithm. In other implementations the system may initialize a quantum simulation using the prepared target quantum state. For example, the system may perform a quantum simulation using the prepared quantum state as an initial state to determine properties of a physical system. For example, the system may perform a quantum simulation to determine properties of a chemical, e.g., a rate of a chemical reaction, as part of a drug discovery process. As another example, the system may perform a quantum simulation to determine properties of a material, e.g., the conductivity of a semiconductor, as part of a design and manufacturing process.

Example Unary Iteration Quantum Circuit Construction

FIG. 4 shows an example unary iteration quantum circuit 400. For convenience, the example unary iteration quantum circuit 400 is illustrated as being configured for reading 8 data items d₀-d₇, e.g., data items representing superposition state amplitudes. However, in some cases the circuit may be expanded (or reduced) and configured to load an arbitrary number of data items, e.g., for preparing arbitrary superposition states.

The example unary iteration quantum circuit 400 includes an index register 402 including thee index qubits. The upper most index qubit represents the most significant bit, and the lowest index qubit represents the least significant bit. The index register 402 is configured to store an index value. The index value, as described with reference to FIG. 3, may correspond to a computational basis state. For example, the index value 011 may correspond to a third computational basis state |D₃

.

The example unary iteration quantum circuit 400 includes a control register 404 including four control qubits. In this description, the lowest control qubit is referred to as the final control qubit. The example unary iteration quantum circuit 400 also includes a data register 406 including eight data qubits. This data register corresponds to the computational basis states of the superposition state that is to be prepared.

The control register 404 encodes the index value encoded in the index register 402 via an iterative cascade of multiple logical AND operations performed between respective pairs of control qubits and index qubits, where each control qubit is made available to the cascade of operations in sequence and not in parallel. At the end of the iterative cascade, the result of a logical AND operation between an inverse of the index qubit representing the least significant bit and the penultimate control qubit storing a result of a previous logical AND operation is stored in the final control qubit.

The example unary iteration quantum circuit 400 repeatedly computes and uncomputes the control qubits to load a data item, e.g., one of data items d₀-d₇, corresponding to the index value to the data register of data qubits. In between each repetition, a CNOT operation is performed between the last uncomputed control qubit and the next most highest control qubit, with the next most highest control qubit acting as the control. For example, between repetition 1 and repetition 2, a CNOT gate 408 is performed between the third control qubit and the second control qubit, with the second control qubit acting as the control. Between repetition 2 and 3, a CNOT gate is performed between the second control qubit and the first control qubit, with the first control qubit acting as the control.

The number of repetitions included in a data loading quantum circuit depends on the number of distinct data loading operations and/or the number of index qubits in the index register. For example, the example unary iteration quantum circuit 400 includes three index qubits and eight distinct data loading operations. Therefore, in this case, the number of compute/uncompute repetitions is equal to 4.

A repetition of computing and uncomputing the control qubits includes iteratively computing one or more logical AND operations between pairs of control and index qubits to store a result of the computations in the final control qubit. If the final control qubit is in an ON state, a multi target CNOT operation is performed on the data register qubits with the final control qubit acting as a control for the multi target CNOT operation. The multi target CNOT operation is dependent on a binary encoding of the data item. For example, if the data item has a binary representation of 10000001, the multi target CNOT operation may include a multi target CNOT operation controlled by the final control qubit that targets the qubits in the data register at offset 0 and 7, i.e., applies CNOTs to the first and the last qubit in the data register. As another example, if the data item has a binary representation of 00001111, the multi target CNOT operation may include a multi target CNOT operation controlled by the final control qubit that targets the last four qubits in the data register.

A CNOT operation is then performed between the final control qubit and the penultimate control qubit, where the penultimate control qubit acts as the control for the CNOT operation. Then, if the final control qubit is in an ON state, a multi target CNOT operation is performed on the data register qubits, again where the multi target CNOT operation is dependent on a binary encoding of the data item. Pairs of control and index qubits are then iteratively uncomputed.

The number of iterative computations and uncomputations performed in a repetition depends which repetition is being performed.

The unary iteration quantum circuit 400 ends by uncomputing the iteratively computed cascade of logical AND operations using a second cascade of uncomputations. Each control qubit is made available to the cascade of uncomputations in sequence and not in parallel.

The above described unary iteration quantum circuit 400 and variations thereof can be used to construct a “read only” type of QRAM, referred to as QROM. A QROM can read classical data indexed by a quantum register using a data loading quantum circuit, i.e. perform the example transformation given below in Equation (5),

$\begin{matrix} {{{QROM}_{d} \cdot {\sum\limits_{l = 0}^{L - 1}{\alpha_{l}\left. l \right\rangle\left. 0 \right\rangle}}} = {\sum\limits_{l = 0}^{L - 1}{\alpha_{l}\left. l \right\rangle\left. D_{l} \right\rangle}}} & (5) \end{matrix}$

In Equation (5), l represents an index to be read and d_(l) represents a word at offset l in a classical list d containing L words (items of data), with each word consisting of D bits, and α_(l) are arbitrary amplitudes. The left hand side of Equation (3) describes an arbitrary superposition over the index register's L possible values with a second register in the state |0

and the left-multiplication of QROM_(d) indicates the application of the QROM circuit. The right hand side of Equation (5) describes the state resulting from the application of the QROM circuit which has the data bits d_(l) in the second register entangled with each possible computational basis state of the first register.

The quantum circuit 400 (and therefore the QROM construction) has a gate complexity of O(L D), since each of the D bits in each of the L words or data items from the QROM determines whether or not a CNOT gate is present and it is possible that all of the QROM's bits are set. However, because the CNOT is a Clifford operation, it is cheap to apply. This is especially so for multi-target CNOT operations, which can be combined into a single braiding operation in the surface code. The T-count of the circuit comes entirely from the unary iteration process (and is independent of data item size) whose T-count is upper bounded by 4L−4.

Furthermore, since the T count is independent of data item size, the data item size can be (artificially) increased without affecting the T count by reading d′_(l)=concat(d_(2l), d_(2l+1)) instead of d_(l). This changes the T-count from 4L to 2L+4D, which is beneficial as long as D is less than L/2.

Example Method for Performing Data Loading

FIG. 5 is a flowchart of an example process 500 for loading data using unary iteration techniques. For convenience, the process 500 will be described as being performed by a quantum computing device in communication with one or more classical computing devices located in one or more locations. For example, the system 200 of FIG. 2, appropriately programmed in accordance with this specification, can perform the process 500.

The system encodes an index value in an index register comprising one or more index qubits (step 502), wherein the index value may be obtained through the process of some larger quantum computation. For example, as illustrated above with reference to FIG. 4, the system may include an index register with N qubits and encode an index value l with 0≤l<2^(N-1). In some cases the index register may not encode an out-of-range value l≥2^(N-1).

The system encodes the index value in a control register comprising multiple control qubits (step 504). Encoding the index value in the control register may include iteratively computing multiple logical AND operations between respective pairs of control qubits and index qubits to store a result of a logical AND operation between an inverse of a least significant index qubit and a penultimate control qubit storing a result of a previous logical AND operation in a final control qubit.

The system repeatedly computes and uncomputes the control qubits to load, conditioned on the state of the control qubits, a data item corresponding to the index value to a data register of data qubits (step 506). Computing and uncomputing one or more control qubits may include repeatedly:

a) determining whether the final control qubit is in an ON state, and in response to determining that the final control qubit is in an ON state, performing a multi target CNOT operation on the data register qubits, wherein the multi target CNOT operation is dependent on a binary encoding of the data item and the final control qubit acts as the control for the multi target CNOT operation;

b) determining a number of uncomputations of the iteratively computed logical AND operations described with reference to step 904 to perform;

c) performing the determined number of uncomputations;

d) performing a CNOT operation between a control qubit corresponding to the last uncomputed logical AND operation and a next highest control qubit, wherein the next highest control qubit acts as a control for the CNOT operation;

e) iteratively computing a number of logical AND operations as described above with reference to step 904 to recompute the final control qubit.

Determining a number of uncomputations of the iteratively computed logical AND operations to perform includes determining how many bits are flipped when changing the binary representation of an index value corresponding to a final control qubit to the next (or, equivalently, the number of times it is possible to divide the index value in base 10 by 2 before the result becomes a non-integer). The number of uncomputations to perform is then equal to the determined number of required bit flips minus 1. Alternatively, the number of uncomputations to perform is equal to the number of times the value of the next index value can be divided by 2 before a non-integer result is obtained.

For example, for a first repetition, a multi target CNOT operation 410 is performed on the data register qubits 406 if the final control qubit is in an ON state, with the multi target CNOT operation 410 being dependent on a binary encoding of the data item do and the final control qubit acting as the control for the multi target CNOT operation 410. No uncomputations are then performed. A CNOT operation 412 is then performed between the final control qubit and a penultimate control qubit. No logical AND operations are then performed.

As another example, for a sixth repetition, a multi target CNOT operation 414 is performed on the data register qubits 406 if the final control qubit is in an ON state, with the multi target CNOT operation 414 being dependent on a binary encoding of the data item d₅ and the final control qubit acting as the control for the multi target CNOT operation 414. One uncomputation is then performed. A CNOT operation 416 is then performed between the penultimate control qubit and a next highest control qubit. One logical AND operation is then performed.

In some implementations, the system may further uncompute the iteratively computed multiple logical AND operations between respective pairs of control qubits and index qubits, as described above with reference to step 502, to reset the index register to encode the index value.

Programming the Hardware: Preparing Superposition States Using Two-Dimensional Rotations in the Space of Computational Basis States

FIG. 6 is a flow diagram of an example process 600 for preparing a quantum state of a quantum system register on a quantum computer, wherein the target quantum state comprises a superposition of L computational basis states. In some implementations the superposition of L computational basis states may have been determined using an adaptive sampling configuration interaction method.

For convenience, the process 600 will be described as being performed by a system of one or more classical or quantum computing devices located in one or more locations. For example, a quantum computation system, e.g., the system 200 of FIG. 2, appropriately programmed in accordance with this specification, can perform the process 600.

The example process 600 proceeds in sequence for each index 1=1 to l=L. For each index, the system prepares the quantum system register and a unary register in a quantum state given by Equation (6) below (step 602).

|ψ_(l)

=β_(l) |D _(l)

|1

+Σ_(l′=1) ^(l-1)α_(l′) |D _(l)

|0

.  (6)

In Equation (6), l represents the index, |D_(l)

represents the l-th computational basis state, α_(j) represents the amplitude of the j-th computational basis state, and |β_(l)|=√{square root over (1−Σ_(l′=1) ^(l-1)|α_(l′)|²)} can be derived from normalization.

The system selects a qubit k from the quantum system register whose value is different in |D_(l)

and |D_(l+1)

(step 604). That is, the system selects a qubit from the quantum system whose occupation numbers d_(l,k) and d_(l+1,k) are different.

The system applies a rotation to the selected qubit (step 606), wherein the rotation is controlled by the state of a unary register. For example, the system maps

β_(l) |D _(l)

|1

(α_(l) |D _(l)

β_(l+1) X _(k) |D _(l)

)|1

  (7)

where X_(k) represents a Pauli X gate operating on qubit k.

The system erases the unary register value for |D_(l)

(step 608). Equation (8) gives an example mapping produced by this operation.

|D _(l)

1

|D _(l)

|0

  (8)

Erasing the unary register requires O(N) Clifford gates and O(1) T gates.

The system implements a NOT logic gate on the remaining qubits whose values are different in |D_(l)

and |D_(l+1)

, wherein implementation of the NOT logic gate is controlled by the state of the unary register (step 610). For example, by implementing the NOT gates in this manner, the system can perform the example mapping given below by Equation (9).

β_(l) |D _(l)

|1

α_(l) |D _(l)

|0

+β_(l+1) |D _(l+1)

|1

  (9)

By combining the above mappings, the system maps the state |ψ_(l)

defined in step 602 to the state |ψ_(l+1)

for the next iteration.

The process 600 requires O(NL) Clifford gates and O(L) T gates. In some implementations the system may further order the computational basis states such that the Hamming distances between neighboring computational basis states are reduced. Ordering the computational basis states in this manner can reduce the total number of gates required to perform the process 600.

In some implementations the system may provide the prepared quantum state for use in a quantum phase estimation algorithm. In other implementations the system may initialize a quantum simulation using the prepared target quantum state. For example, the system may perform a quantum simulation using the prepared quantum state as an initial state to determine properties of a physical system. For example, the system may perform a quantum simulation to determine properties of a chemical, e.g., a rate of a chemical reaction, as part of a drug discovery process. As another example, the system may perform a quantum simulation to determine properties of a material, e.g., the conductivity of a semiconductor, as part of a design and manufacturing process.

Adaptive Sampling Configuration Interaction Method

The Adaptive Sampling Configuration Interaction (ASCI) method performs a diagonalization on a determinant space in which as many important degrees of freedom as possible is captured. This principle motivates most exact diagonalization and configuration interaction (CI) techniques, but most methods do not allow for explicit searching for important determinants. In contrast with some CI techniques, the idea of using a selected CI approach is to generate a relatively small set of determinants that account for 90% or more of the top contributions to the full CI wavefunction.

In selected CI methods, a wavefunction ψ_(k) is iteratively improved to reach a desired accuracy, beginning with a single determinant approximation. The search part of the algorithm has two rules: a selection criterion to determine what part of Hilbert space to search for new determinants (pruning) and a ranking criterion to determine the best determinants to include in the improved wavefunction ψ_(k+1).

For the applications considered in this specification, the ranking criterion can be derived from a consistency relation among the coefficients of determinants in the eigenstate approximation. Expressing the time-independent Schrödinger equation H|ψ

=E|ψ

in the basis of determinants so that |ψ

=Σ_(i) C_(i)|D_(i)

, where |D_(i)

represents the ith determinant, Equation (10) can be obtained

$\begin{matrix} {C_{i} = \frac{\sum\limits_{i \neq j}{H_{ij}C_{j}}}{E - H_{ii}}} & (10) \end{matrix}$

where H_(ij)=

D_(i)|H|D_(j)

represents the Hamiltonian matrix element between the ith and jth determinants. Equation (10) can be used to predict a new and better set of determinants by taking the left hand side as an estimate of the magnitude of the expansion coefficients, as given in Equation (11):

$\begin{matrix} {C_{i}^{k + 1} = \frac{\sum\limits_{i \neq j}{H_{ij}C_{j}^{k}}}{E_{k} - H_{ii}}} & (11) \end{matrix}$

where E_(k)=

ψ_(k)|H|ψ_(k)

represents the energy of the wavefunction in the kth iteration. For coefficients corresponding to an exact eigenstate of H, C_(i) ^(k+1)=C_(i) ^(k). Since the goal of selected CI is to include the most important weight determinants in the expansion, this equation can be used to rank the determinants by magnitude of C_(i) ^(k+1). These coefficients are related to a first-order perturbation estimate for CI coefficients in many body perturbation theory.

In practice this iterative approach generates all the top contributions to the wavefunction. Having the top contributions is important to obtain highly accurate energies, as can be seen by combining the ASCI method with second order many body perturbation theory.

FIG. 7 is a flow diagram of an example ASCI algorithm. The computational parts include search, diagonalization, and post-processing steps. The growth steps are performed in the first set of iterations of ASCI to bring the variational wavefunction from the Hartree-Fock determinant to a wavefunction of size N_(tdets). The wavefunction is grown, since it is slower to perform diagonalizations on a full size but inaccurate wavefunction. The refinement steps can be used when a very high accurate variational wavefunction is to be generated. During the refinement step the size of the wavefunction can be fixed but it is continually improved upon through search/diagonalization iterations.

Implementations of the digital and/or quantum subject matter and the digital functional operations and quantum operations described in this specification can be implemented in digital electronic circuitry, suitable quantum circuitry or, more generally, quantum computational systems, in tangibly-embodied digital and/or quantum computer software or firmware, in digital and/or quantum computer hardware, including the structures disclosed in this specification and their structural equivalents, or in combinations of one or more of them. The term “quantum computational systems” may include, but is not limited to, quantum computers, quantum information processing systems, quantum cryptography systems, or quantum simulators.

Implementations of the digital and/or quantum subject matter described in this specification can be implemented as one or more digital and/or quantum computer programs, i.e., one or more modules of digital and/or quantum computer program instructions encoded on a tangible non-transitory storage medium for execution by, or to control the operation of, data processing apparatus. The digital and/or quantum computer storage medium can be a machine-readable storage device, a machine-readable storage substrate, a random or serial access memory device, one or more qubits, or a combination of one or more of them. Alternatively or in addition, the program instructions can be encoded on an artificially-generated propagated signal that is capable of encoding digital and/or quantum information, e.g., a machine-generated electrical, optical, or electromagnetic signal, that is generated to encode digital and/or quantum information for transmission to suitable receiver apparatus for execution by a data processing apparatus.

The terms quantum information and quantum data refer to information or data that is carried by, held or stored in quantum systems, where the smallest non-trivial system is a qubit, i.e., a system that defines the unit of quantum information. It is understood that the term “qubit” encompasses all quantum systems that may be suitably approximated as a two-level system in the corresponding context. Such quantum systems may include multi-level systems, e.g., with two or more levels. By way of example, such systems can include atoms, electrons, photons, ions or superconducting qubits. In many implementations the computational basis states are identified with the ground and first excited states, however it is understood that other setups where the computational states are identified with higher level excited states are possible.

The term “data processing apparatus” refers to digital and/or quantum data processing hardware and encompasses all kinds of apparatus, devices, and machines for processing digital and/or quantum data, including by way of example a programmable digital processor, a programmable quantum processor, a digital computer, a quantum computer, multiple digital and quantum processors or computers, and combinations thereof. The apparatus can also be, or further include, special purpose logic circuitry, e.g., an FPGA (field programmable gate array), an ASIC (application-specific integrated circuit), or a quantum simulator, i.e., a quantum data processing apparatus that is designed to simulate or produce information about a specific quantum system. In particular, a quantum simulator is a special purpose quantum computer that does not have the capability to perform universal quantum computation. The apparatus can optionally include, in addition to hardware, code that creates an execution environment for digital and/or quantum computer programs, e.g., code that constitutes processor firmware, a protocol stack, a database management system, an operating system, or a combination of one or more of them.

A digital computer program, which may also be referred to or described as a program, software, a software application, a module, a software module, a script, or code, can be written in any form of programming language, including compiled or interpreted languages, or declarative or procedural languages, and it can be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a digital computing environment. A quantum computer program, which may also be referred to or described as a program, software, a software application, a module, a software module, a script, or code, can be written in any form of programming language, including compiled or interpreted languages, or declarative or procedural languages, and translated into a suitable quantum programming language, or can be written in a quantum programming language, e.g., QCL or Quipper.

A digital and/or quantum computer program may, but need not, correspond to a file in a file system. A program can be stored in a portion of a file that holds other programs or data, e.g., one or more scripts stored in a markup language document, in a single file dedicated to the program in question, or in multiple coordinated files, e.g., files that store one or more modules, sub-programs, or portions of code. A digital and/or quantum computer program can be deployed to be executed on one digital or one quantum computer or on multiple digital and/or quantum computers that are located at one site or distributed across multiple sites and interconnected by a digital and/or quantum data communication network. A quantum data communication network is understood to be a network that may transmit quantum data using quantum systems, e.g. qubits. Generally, a digital data communication network cannot transmit quantum data, however a quantum data communication network may transmit both quantum data and digital data.

The processes and logic flows described in this specification can be performed by one or more programmable digital and/or quantum computers, operating with one or more digital and/or quantum processors, as appropriate, executing one or more digital and/or quantum computer programs to perform functions by operating on input digital and quantum data and generating output. The processes and logic flows can also be performed by, and apparatus can also be implemented as, special purpose logic circuitry, e.g., an FPGA or an ASIC, or a quantum simulator, or by a combination of special purpose logic circuitry or quantum simulators and one or more programmed digital and/or quantum computers.

For a system of one or more digital and/or quantum computers to be “configured to” perform particular operations or actions means that the system has installed on it software, firmware, hardware, or a combination of them that in operation cause the system to perform the operations or actions. For one or more digital and/or quantum computer programs to be configured to perform particular operations or actions means that the one or more programs include instructions that, when executed by digital and/or quantum data processing apparatus, cause the apparatus to perform the operations or actions. A quantum computer may receive instructions from a digital computer that, when executed by the quantum computing apparatus, cause the apparatus to perform the operations or actions.

Digital and/or quantum computers suitable for the execution of a digital and/or quantum computer program can be based on general or special purpose digital and/or quantum processors or both, or any other kind of central digital and/or quantum processing unit. Generally, a central digital and/or quantum processing unit will receive instructions and digital and/or quantum data from a read-only memory, a random access memory, or quantum systems suitable for transmitting quantum data, e.g. photons, or combinations thereof.

The elements of a digital and/or quantum computer are a central processing unit for performing or executing instructions and one or more memory devices for storing instructions and digital and/or quantum data. The central processing unit and the memory can be supplemented by, or incorporated in, special purpose logic circuitry or quantum simulators. Generally, a digital and/or quantum computer will also include, or be operatively coupled to receive digital and/or quantum data from or transfer digital and/or quantum data to, or both, one or more mass storage devices for storing digital and/or quantum data, e.g., magnetic, magneto-optical disks, optical disks, or quantum systems suitable for storing quantum information. However, a digital and/or quantum computer need not have such devices.

Digital and/or quantum computer-readable media suitable for storing digital and/or quantum computer program instructions and digital and/or quantum data include all forms of non-volatile digital and/or quantum memory, media and memory devices, including by way of example semiconductor memory devices, e.g., EPROM, EEPROM, and flash memory devices; magnetic disks, e.g., internal hard disks or removable disks; magneto-optical disks; CD-ROM and DVD-ROM disks; and quantum systems, e.g., trapped atoms or electrons. It is understood that quantum memories are devices that can store quantum data for a long time with high fidelity and efficiency, e.g., light-matter interfaces where light is used for transmission and matter for storing and preserving the quantum features of quantum data such as superposition or quantum coherence.

Control of the various systems described in this specification, or portions of them, can be implemented in a digital and/or quantum computer program product that includes instructions that are stored on one or more non-transitory machine-readable storage media, and that are executable on one or more digital and/or quantum processing devices. The systems described in this specification, or portions of them, can each be implemented as an apparatus, method, or system that may include one or more digital and/or quantum processing devices and memory to store executable instructions to perform the operations described in this specification.

While this specification contains many specific implementation details, these should not be construed as limitations on the scope of what may be claimed, but rather as descriptions of features that may be specific to particular implementations. Certain features that are described in this specification in the context of separate implementations can also be implemented in combination in a single implementation. Conversely, various features that are described in the context of a single implementation can also be implemented in multiple implementations separately or in any suitable sub-combination. Moreover, although features may be described above as acting in certain combinations and even initially claimed as such, one or more features from a claimed combination can in some cases be excised from the combination, and the claimed combination may be directed to a sub-combination or variation of a sub-combination.

Similarly, while operations are depicted in the drawings in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order, or that all illustrated operations be performed, to achieve desirable results. In certain circumstances, multitasking and parallel processing may be advantageous. Moreover, the separation of various system modules and components in the implementations described above should not be understood as requiring such separation in all implementations, and it should be understood that the described program components and systems can generally be integrated together in a single software product or packaged into multiple software products.

Particular implementations of the subject matter have been described. Other implementations are within the scope of the following claims. For example, the actions recited in the claims can be performed in a different order and still achieve desirable results. As one example, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some cases, multitasking and parallel processing may be advantageous. 

1. A method for preparing a quantum state of a quantum system register on a quantum computer, wherein the quantum state comprises a superposition of L computational basis states, the method comprising: preparing a register of log L qubits in an initial state, the initial state comprising a weighted sum of register basis states, wherein: each register basis state indexes a corresponding quantum state computational basis state, and the amplitude of each register basis state in the weighted sum of register basis states is equal to the amplitude of the corresponding computational basis state in the superposition of L computational basis states; and preparing the quantum state by implementing a unitary transformation that maps the register basis states to the corresponding L computational basis states, comprising, for each index 1 to L, controlling, by the register of log L qubits, transformation of the quantum system register state for the index to the corresponding computational basis state for the index.
 2. The method of claim 1, wherein implementing a unitary transformation that maps the register basis states to the corresponding L computational basis states comprises implementing a unary iteration quantum circuit.
 3. The method of claim 1, wherein controlling transformation of the quantum system register state for the index to the corresponding computational basis state for the index comprises controlling applications of unitary operators on the quantum system register state by a state of a unary register, wherein the state of the unary register is determined by the register of log L qubits.
 4. The method of claim 3, wherein controlling applications of unitary operators on the quantum system register state by a state of a unary register comprises, for each index 1 to L: reading the computational basis state corresponding to the index to the quantum system register, comprising applying a unitary operator for the index to the system register controlled by the unary register; erasing the state of the register of log L qubits using a unitary operator controlled by the unary register; and uncomputing the unary register.
 5. The method of claim 4, further comprising providing the register of log L qubits for use in further computations.
 6. The method of claim 3, wherein controlling applications of unitary operators on a system register encoding the quantum state by a unary register comprising the register of log L qubits comprises controlling applications of products of Pauli-X quantum logic gates.
 7. The method of claim 1, wherein implementing a unitary transformation that maps the register basis states to the corresponding L computational basis states comprises applying select unitary methods.
 8. The method of claim 1, wherein preparing the register of log L qubits in the initial state comprises applying quantum circuit synthesis techniques.
 9. The method of claim 1, wherein the superposition of L computational basis states is determined using an adaptive sampling configuration interaction method.
 10. The method of claim 1, further comprising providing the quantum state for use in a quantum phase estimation algorithm.
 11. The method of claim 1, further comprising: performing a quantum simulation using the prepared quantum state as an initial state of the quantum simulation.
 12. The method of claim 1, wherein the quantum computer comprises a circuit model quantum computer.
 13. An apparatus comprising: quantum hardware; and one or more classical processors; wherein the apparatus is configured to perform operations comprising the method of any preceding claim.
 14. The apparatus of claim 13, wherein the quantum hardware comprises: a quantum circuit comprising: a quantum system register comprising multiple target qubits; an index register comprising log L index qubits; a control register comprising multiple control qubits; one or more control devices configured to operate the quantum circuit and cause the quantum circuit to perform the method of claim
 1. 15. A method for preparing a target quantum state of a quantum system register on a quantum computer, wherein the target quantum state comprises a superposition of L computational basis states, the method comprising, sequentially for each index 1=1 to 1=L: preparing the quantum system register and a unary register in a quantum state, wherein: the state of the quantum system register is entangled with the unary register, at an initial time step the state of the quantum system register equals the target quantum state up to the first (l−1) computational basis states if the state of the unary register is |0

, and the state of the quantum system register equals the l-th computational basis state if the unary register is in state |1

; selecting a qubit from the quantum system register whose value is different in the l-th computational basis state and the l+1-th computational basis state; applying a rotation to the selected qubit, wherein the rotation is controlled by the state of a unary register; erasing the unary register value for the l-th computational basis state; and implementing a NOT logic gate on the remaining qubits in the quantum system register whose values are different in the l-th computational basis state and the l+1-th computational basis state, wherein implementation of the NOT logic gate is controlled by the state of the unary register.
 16. The method of claim 15, wherein preparing the quantum system register and a unary register in a quantum state comprises preparing the quantum system register and unary register in a quantum state |ψ_(l)

=β_(t)|D_(l)

+Σ_(l′=1) ^(l-1)α_(l), |D_(l′)

|0

, wherein 1 represents the index, |D_(l)

represents the l-th computational basis state, a represents a computational basis state amplitude, and |β_(l)|=√{square root over (1−Σ_(l′=1) ^(l-1)|α_(l′)|²)}.
 17. The method of claim 15, further comprising ordering the computational basis states such that the Hamming distances between neighboring computational basis states are reduced.
 18. The method of claim 15, wherein applying a rotation to the selected qubit comprises applying a Pauli X gate to the selected qubit.
 19. The method of claim 15, wherein selecting a qubit from the quantum system register whose value is different the l-th computational basis state and the l+1-th computational basis state comprises selecting a qubit from the quantum system whose occupation numbers d_(l,k) and d_(l+1,k) are different.
 20. The method of claim 15, wherein the amplitude of the l-th basis state is derived from normalization.
 21. The method of claim, 16, wherein |β_(l)| is derived from normalization.
 22. The method of claim 15, wherein the superposition of L computational basis states is determined using an adaptive sampling configuration interaction method.
 23. The method of claim 15, further comprising providing the target quantum state for use in a quantum phase estimation algorithm.
 24. The method of claim 15, further comprising: initializing a quantum simulation using the prepared target quantum state; and performing a the quantum simulation.
 25. An apparatus comprising: quantum hardware; and one or more classical processors; wherein the apparatus is configured to perform operations comprising the method of claim
 15. 26. The apparatus of claim 25, wherein the quantum hardware comprises: a quantum circuit comprising: a quantum system register comprising multiple target qubits; a unary register comprising multiple control qubits; one or more control devices configured to operate the quantum circuit and cause the quantum circuit to perform the method of claim
 15. 